package com.itkaien.saaexample.config;

import com.alibaba.cloud.ai.dashscope.api.DashScopeAgentApi;
import com.alibaba.cloud.ai.dashscope.api.DashScopeApi;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * LLM配置
 */
@Configuration
public class SaaLLMConfig {

    @Value("sk-7465bfe24bcf4f5a8db8b1ae9a9078df")
    private String apiKey;

    @Bean
    public DashScopeApi dashScopeApi() {
        return  DashScopeApi.builder()
                .apiKey(apiKey)
                .build();
    }
}
